home *** CD-ROM | disk | FTP | other *** search
- Path: keats.ugrad.cs.ubc.ca!not-for-mail
- From: c2a192@ugrad.cs.ubc.ca (Kazimir Kylheku)
- Newsgroups: comp.lang.c
- Subject: Re: calloc help needed
- Date: 16 Feb 1996 20:27:49 -0800
- Organization: Computer Science, University of B.C., Vancouver, B.C., Canada
- Message-ID: <4g3lg5INNs1c@keats.ugrad.cs.ubc.ca>
- References: <1996Feb15.125431.7751@leeds.ac.uk> <4fvmgbINNbp0@keats.ugrad.cs.ubc.ca> <danpop.824470182@rscernix>
- NNTP-Posting-Host: keats.ugrad.cs.ubc.ca
-
- In article <danpop.824470182@rscernix>, Dan Pop <danpop@mail.cern.ch> wrote:
- >In <4fvmgbINNbp0@keats.ugrad.cs.ubc.ca> c2a192@ugrad.cs.ubc.ca (Kazimir Kylheku) writes:
- >
- >>In article <1996Feb15.125431.7751@leeds.ac.uk>,
- >>A M Casey <csyamc@scs.leeds.ac.uk> wrote:
- >>
- >> >doesnt work, as far as I can tell calloc returns an int.
- >>
- >>It is probably "implicitly defined" to return an int, because you lack a
- >>declaration. Try including the "malloc.h" header file.
- >
- >You misspelled <stdlib.h>. There is no such thing as "malloc.h" defined
- >by the C standard. There is an /usr/include/malloc.h on my system,
- >but it doesn't contain any declaration for calloc (the only functions
- >declared there are mallinfo and mallopt).
-
- Ah, right. No such thing as a standard malloc.h indeed. I think that I'm
- suffering from having used too many brain-damaged systems. I should have
- checked that one instead of being lazy. The system I'm on right now has the
- declarations in both places. Argh. I know that I came up with the idea
- including "malloc.h" in some situation where it had to be done and somehow it
- stuck in my memory.
-
- My apologies. Even K&R doesn't mention <malloc.h> as a standard header.
- --
-
-